package com.itheima.多态.成员访问特点;

public class Test1 {
    public static void main(String[] args) {
    Fu f=new Zi();
        System.out.println(f.num);
        f.method();
    }
}

class Fu{
    int num=10;
    public void method(){
        System.out.println("Fu...method");
    }
}

class Zi extends Fu{
    int num=30;
    public void method(){
        System.out.println("Zi...method");
    }
}